#ifndef WORDSEGHANDLER_H_
#define WORDSEGHANDLER_H_

#include "scwdef.h"
#include "isegment.h"

#include <pthread.h>

class WordSegHandler
{
    private:
        WordSegHandler();
        WordSegHandler(const WordSegHandler&);
        WordSegHandler & operator = (const WordSegHandler&);

        scw_worddict_t* _segdict;

        static WordSegHandler* _instance;
        static pthread_mutex_t _mutex;

    public:
        static WordSegHandler* Instance();

        scw_worddict_t* GetWordSegDicts()
        {
            return _segdict;
        }
};


#endif /* WORDSEGHANDLER_H_ */
